/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package modele;

/**
 *
 * @author gazzopardi
 */


public class Medecin implements Comparable<Medecin>{
    private String nom;
    private String prenom;
    private String adresse;
    private String tel;
    private String specialite;
    private String id;

    public Medecin(String nom, String prenom, String adresse, String tel, String specialite, String id) {
        this.nom = nom;
        this.prenom = prenom;
        this.adresse = adresse;
        this.tel = tel;
        this.specialite = specialite;
        this.id = id;
    }

    public String getAdresse() {
        return adresse;
    }

    public String getNom() {
        return nom;
    }

    public String getPrenom() {
        return prenom;
    }

    public String getSpecialite() {
        return specialite;
    }

    public String getTel() {
        return tel;
    }
    
    @Override
    public int compareTo(Medecin m){
        if(nom.compareTo(m.nom)==0)
        {return prenom.compareTo(m.prenom);}
        else 
        {
            return nom.compareTo(m.nom);
    }
 
    
    
}
}